@import '../var';

strong {
  @each $name, $pair in $base-colors {
    $color: nth($pair, 1);
    $color-invert: nth($pair, 2);
    &.is-#{$name} {
      color: $color;
      background-color: $color-invert;
    }
    &.is-#{$name}-invert {
      color: $color-invert;
      background-color: $color;
    }
  }
  @each $name, $pair in $colors {
    $color: nth($pair, 1);
    $color-invert: nth($pair, 2);
    &.is-#{$name} {
      color: $color;
      background-color: $color-invert;
    }
    &.is-#{$name}-invert {
      color: $color-invert;
      background-color: $color;
    }
    @if length($pair) >= 4 {
      $color-light: nth($pair, 3);
      $color-dark: nth($pair, 4);
      &.is-#{$name}-light {
        color: $color-light;
        background-color: $color-dark;
      }
      &.is-#{$name}-dark {
        color: $color-dark;
        background-color: $color-light;
      }
    }
  }
}
